

                <div class="row">
                    <div class="col-md-12">
                        <form id="wizardForm" class="form-horizontal" method="" action="" >

                            <div class="row">
                                <div class="col-xs-4 app">
                                    <div class="phone-view">
                                        <div class="app-view">
                                            <div class="app-mainC">
                                                <div class="app-alert">
                                                    <div class="app-alert-input">
                                                        <div class="app-alert-image">
                                                            <img src="/images/admin/promotion_default.png">
                                                        </div>
                                                        <div class="app-alert-title">
                                                            <div class="title-name">活动名称</div>
                                                            <div class="title-endtime">有效期:<span class="title-endtime-span"></span></div>
                                                        </div>

                                                    </div>
                                                    <div class="app-alert-word displayable">
                                                        <div class="app-alert-code"></div>
                                                        <div class="app-alert-text">
                                                            长按复制卷码去兑奖
                                                        </div>
                                                    </div>

                                                </div>
                                                <div class="app-btn"></div>
                                                <div class="app-paper"></div>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                                <div class="col-xs-8">
                                    <div class="row">
                                        <div class="col-sm-12">
                                            <div class="form-group">
                                                <label class="col-sm-2 col-sm-offset-1 control-label">奖品名称</label>
                                                <div class="col-sm-7 col-sm-offset-1">
                                                    <input class="form-control prize-code-name" type="text"
                                                           name="prizename"
                                                           required="required"
                                                    />
                                                </div>
                                            </div>
                                            <div class="form-group">
                                                <label class="col-sm-2 col-sm-offset-1 control-label">有效时间</label>
                                                <div class="col-sm-7 col-sm-offset-1">
                                                    <div class="row service-charges">
                                                        <div class="col-md-5 service-charges-name service-charges-name-0" style="padding-left: 15px;">
                                                            <input type="date" placeholder="开始时间"  required="" name="startTime" data-msg="请输入开始时间" class="form-control datetimepicker codestartdate">
                                                           <!-- <input type="text" placeholder="开始时间"  required="" name="startTime" data-msg="请输入开始时间" class="form-control datetimepicker">-->
                                                        </div>
                                                        <div class="col-md-5 service-charges-remark service-charges-remark-0">
                                                            <input type="date" placeholder="结束时间"  required="" name="startTime" data-msg="请输入开始时间" class="form-control datetimepicker codeenddate">
                                                           <!-- <input type="text" placeholder="结束时间"  required="required" data-msg="请输入结束时间" name="endTime" class="form-control datetimepicker">-->
                                                        </div>
                                                    </div>
                                                </div>
                                            </div>
                                            {{--<input class="form-control" value="0" type="hidden" name="savenumber"/>--}}
                                            {{--<div class="form-group">--}}
                                                {{--<label class="col-sm-2 col-sm-offset-1 control-label">奖品库存</label>--}}
                                                {{--<div class="col-sm-7 col-sm-offset-1">--}}
                                                    {{--<input class="form-control" type="text"--}}
                                                           {{--placeholder="最大为9999999"--}}
                                                           {{--required="required"--}}
                                                           {{--name="savenumber"--}}
                                                           {{--number="true"--}}
                                                           {{--max="9999999"--}}
                                                    {{--/>--}}
                                                {{--</div>--}}
                                            {{--</div>--}}
                                            {{--<div class="form-group">--}}
                                                {{--<label class="col-sm-2 col-sm-offset-1 control-label">卷码类型</label>--}}
                                                {{--<div class="col-sm-7 col-sm-offset-1">--}}
                                                    {{--<label class="radio-inline">--}}
                                                        {{--<input type="radio" name="couponCode" class="nocode" value="nocode" checked> 无券码--}}
                                                    {{--</label>--}}
                                                    {{--<label class="radio-inline">--}}
                                                        {{--<input type="radio" name="couponCode" class="samecode" value="samecode"> 统一码--}}
                                                    {{--</label>--}}
                                                    {{--<label class="radio-inline">--}}
                                                        {{--<input type="radio" name="couponCode" class="slfcode" value="slfcode"> 自定义导入--}}
                                                    {{--</label>--}}
                                                    {{--<p class="help-block">注意：奖品保存后券码类型不能修改。</p>--}}
                                                {{--</div>--}}
                                            {{--</div>--}}
                                            {{--<div class="samecouponCode-input displayable">--}}
                                                {{--<div class="form-group">--}}
                                                    {{--<label class="col-sm-2 col-sm-offset-1 control-label">统一卷码</label>--}}
                                                    {{--<div class="col-sm-7 col-sm-offset-1">--}}
                                                        {{--<input class="form-control input-same-code" type="text"--}}
                                                               {{--placeholder="请输入卷码"--}}
                                                               {{--name="couponCodeContent"--}}
                                                        {{--/>--}}
                                                    {{--</div>--}}
                                                {{--</div>--}}
                                            {{--</div>--}}
                                            <div class="slfcouponCode-input displayable">
                                                <div class="form-group">
                                                    <label class="col-sm-2 col-sm-offset-1 control-label">上传卷码</label>
                                                    <div class="col-sm-7 col-sm-offset-1">
                                                        <input type="file" name="slfcouponCode" accept="text/comma-separated-values">
                                                        <p class="help-block">"提示：CSV格式，每次最多导入10000条记录。下载["
                                                            <a href="/admin/卷码示例.csv" target="_blank">示例</a>
                                                            "]"</p>
                                                    </div>
                                                </div>
                                            </div>

                                            <div class="form-group">
                                                <label class="col-sm-2 col-sm-offset-1 control-label">兑奖链接</label>
                                                <div class="col-sm-7 col-sm-offset-1">
                                                    <input class="form-control exchange_url" type="text"
                                                           placeholder="例如：http://www.chinamcloud.com"
                                                           name="prizeUrl"
                                                           url="true"
                                                    />
                                                </div>
                                            </div>
                                            <div class="form-group">
                                                <label class="col-sm-2 col-sm-offset-1 control-label">奖品标签</label>
                                                <div class="col-sm-7 col-sm-offset-1">
                                                    <input class="form-control" type="text"
                                                           name="prize[title]"
                                                    />
                                                </div>
                                            </div>
                                            <div class="form-group backgroundImg-container" >
                                                <label class="col-sm-2 col-sm-offset-1 control-label">更换背景</label>
                                                <div class="col-sm-7 col-sm-offset-1">
                                                    <input type="file" name="upfile" accept="image/gif,image/jpeg,image/png" data-target="uploadImageFile" data-for="backgroundImg" data-preview-file-type="text" class="form-control" value="" title="">
                                                    <input type="hidden" name="backgroundImg">
                                                    <span class="help-block">100*100像素，支持PNG、JPG格式，小于200KB</span>
                                                </div>
                                            </div>
                                            <div class="row">
                                                <div class="col-sm-9 col-sm-offset-2">
                                                    <div class="panel panel-info">
                                                        <div class="panel-heading">
                                                            <h3 class="panel-title">奖品赞助商信息</h3>
                                                        </div>
                                                        <div class="panel-body sponsor_panel">
                                                            <div class="sponsor_form">
                                                                <div class="row">
                                                                    <div class="col-sm-12">
                                                                        <img src="/images/admin/delet_red.png" class="sponsor_delet pull-right mgb10 mgr30">
                                                                    </div>
                                                                    <div class="form-group">
                                                                        <label class="col-sm-3 control-label">赞助商信息</label>
                                                                        <div class="col-sm-8 ">
                                                                            <input class="form-control" type="text"
                                                                                   name="sponsorInf"
                                                                            />
                                                                        </div>
                                                                    </div>
                                                                    <div class="form-group">
                                                                        <label class="col-sm-3 control-label">商家Logo</label>
                                                                        <div class="col-sm-8">
                                                                            <input type="file" name="upLogo" accept="image/gif,image/jpeg,image/png" data-target="uploadLogoFile" data-for="sponsorLogo" data-preview-file-type="text" class="form-control" value="" title="">
                                                                            <input type="hidden" name="sponsorLogoImg">
                                                                            <span class="help-block">支持PNG、JPG格式，小于200KB</span>
                                                                        </div>
                                                                    </div>
                                                                    <div class="form-group">
                                                                        <label class="col-sm-3 control-label">曝光率</label>
                                                                        <div class="col-sm-7">
                                                                            <input class="form-control ptr" type="text"
                                                                                   name="sponsorInf"
                                                                            />
                                                                        </div>
                                                                        <label class="col-sm-1 control-label ptl textl">%</label>
                                                                    </div>
                                                                </div>
                                                            </div>
                                                            <div class="pull-center mgud">
                                                                <button type="button" class="btn btn-info btn-wd btn-finish panel-sponsor-butten">
                                                                    添加一个新的赞助商
                                                                </button>
                                                            </div>
                                                        </div>
                                                    </div>
                                                </div>
                                            </div>
                                        </div>
                                    </div>

                                </div>
                            </div>
                            <div class="footer pull-center">

                                <button type="button" class="btn btn-info btn-fill btn-wd btn-finish sponsor_sur"
                                >完成
                                </button>

                                <div class="clearfix"></div>
                            </div>

                        </form>
                    </div>
                </div>


    <script>
        $(document).ready(function () {
            $('.nocode').click(function () {

                $('.samecouponCode-input').addClass('displayable');
                $('.slfcouponCode-input').addClass('displayable');
                $('.app-alert-word').addClass('displayable');
            });
            $('.samecode').click(function () {
                $('.app-alert-code').empty();
                $('.samecouponCode-input').removeClass('displayable');
                $('.slfcouponCode-input').addClass('displayable');
                $('.app-alert-word').removeClass('displayable');
            });

            $('.slfcode').click(function () {
                $('.app-alert-code').html('0123456789');
                $('.samecouponCode-input').addClass('displayable');
                $('.slfcouponCode-input').removeClass('displayable');
                $('.app-alert-word').removeClass('displayable');
            });
            
            $('.panel-sponsor-butten').click(function () {
                $.get('/web/modelSponsor',function (res) {
                    $('.sponsor_panel').prepend(res);
                });
            });
            $('.sponsor_delet').click(function () {
                $(this).parents('.sponsor_form').remove();
            });

            $('.prize-code-name').blur(function () {
                if($('.prize-code-name').val()==''){
                    $('.title-name').empty();
                    $('.title-name').html('活动名称');
                }
            });
            $('.prize-code-name').on('input',function () {
                $('.title-name').empty();
                var name=$('.prize-code-name').val();
                $('.title-name').html(name);
            });
            /*统一卷码输入事件*/
            $('.input-same-code').on('input',function () {
                $('.app-alert-code').empty();
                var name=$('.input-same-code').val();
                $('.app-alert-code').html(name);
            });

            $('.codeenddate').on('input',function () {
                var enddate=$(this).val();
                $('.title-endtime-span').html(enddate);
            })

        })
    </script>

